/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
package fr.insta.browser.view.webview;

import javax.swing.JPanel;

/**
 * <p>SwingWebView interface.</p>
 *
 * @author Maarek
 * @version $Id: $Id
 */
public interface SwingWebView {

    /**
     * <p>loadURL.</p>
     *
     * @param url a {@link java.lang.String} object.
     */
    void loadURL(final String url);

    /**
     * <p>getUrl.</p>
     *
     * @return a {@link java.lang.String} object.
     */
    String getUrl();

    /**
     * <p>getPageTitle.</p>
     *
     * @return a {@link java.lang.String} object.
     */
    String getPageTitle();

    /**
     * <p>getPanel.</p>
     *
     * @return a {@link javax.swing.JPanel} object.
     */
    JPanel getPanel();

    /**
     * <p>executeJavaScript.</p>
     *
     * @param js a {@link java.lang.String} object.
     */
    void executeJavaScript(String js);

    /**
     * <p>zoomIn.</p>
     */
    void zoomIn();

    /**
     * <p>zoomOut.</p>
     */
    void zoomOut();

    /**
     * <p>getSource.</p>
     *
     * @return a {@link java.lang.String} object.
     */
    String getSource();
    
    /**
     * <p>addListener.</p>
     *
     * @param listener a {@link fr.insta.browser.view.webview.WebViewListener} object.
     */
    void addListener(WebViewListener listener);

    /**
     * <p>removeListener.</p>
     *
     * @param listener a {@link fr.insta.browser.view.webview.WebViewListener} object.
     */
    void removeListener(WebViewListener listener);
}
